﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Security.Cryptography;
using System.Xml;
using System.IO;
using System.Net;
using System.Data.SqlClient;
using System.Xml.Linq;
using System.Data;
using System.Timers;
namespace FBProductsSynchronization
{
    static class Program
    {

        /*[STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new Form1());
        }
        */
        private static System.Threading.Timer everySecond;
        private static System.Threading.Timer everyDay;
        private static System.Threading.Timer everyHour;
        private static System.Threading.Timer everyHour1;
        private static System.Threading.Timer every10Second;
        static void Main(string[] args)
        {
            try
            {
                
                Config config = new Config();
                Fishbowl Fishbowl = new Fishbowl();
                DataUtility Utility = new DataUtility();
                String key = "";
                config.start();

                ConnectionObject connectionObject = new ConnectionObject();
                connectionObject = config.ReturnConnection();
                key = config.ReturnKey();

                Utility.ExportProducts(connectionObject, key, "ExportProductTree", "Product:Virgin");
                Console.ReadLine();
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message.ToString());
            }
        }
      
    }
}

